package com.larry.java2;

/**
 * @author larry
 * @Title: jvm_dc
 * @Package com.larry.java2
 * @Description: TODO
 * @date 7/29/2112:32 PM
 */
public class T {
    public static int k = 0;
    public static T t1 = new T("t1");
    public static T t2 = new T("t2");
    public static int i = print("i");
    public static int n = 99;


    static {
        print("静态块");
    }

    {
        print("构造块");
    }

    public T(String str){
        System.out.println(" 有参构造 " + (++k) + ":" + str + " i=" + i + " n=" + n);
        ++i;
        ++n;
    }

    public static int j = print("j");



    public static int print(String str){
        System.out.println(" 静态方法 " + (++k) + ":" + str + " i=" + i + " n=" + n);
        ++n;
        return ++i;
    }

    public static void main(String[] args) {

    }
}
